import requests
keyword =  input('请输入地址')

url = 'https://www.kfc.com.cn/kfccda/ashx/GetStoreList.ashx?op=cname'

data = {
"cname": keyword,
"pid": '',
"pageIndex": 1,
"pageSize": 10,
}
head = {
    'user-agent':'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/127.0.0.0 Safari/537.36'

}
response = requests.post(url = url, data=data, headers=head)

page_text = response.json()
# print(page_text)
# print(page_text['Table1'])
for dic in page_text['Table1']:
    name = dic['storeName']
    address = dic['addressDetail']
    print(name, address)